using System;
using Sedna.Core.Globalization;

namespace Sedna.Core.Controller.Configurations
{
	/// <summary>
	/// Summary description for PageConfiguration.
	/// </summary>
	public class PageConfiguration: ClientScriptingConfiguration, IPageConfiguration
    {

        private string editPageUrl;
        private string addPageUrl;
        private string gridClientVariable;
        private string frameClientVariable;
        private string delMessageKey;
        private string printPageUrl;

	    private string sessionKey;
		private ISessionWrapper sessionWrapper;
		private string helpPage;
		private IHelpManager helpManager;

        private string tabHeaderTextBindPath;
	    
	    private string tabHeaderTextKey;
	    private string tabHeaderTextKeyBindPath;

        private string helpPageBindPath;
        private string helpPageUnbindPath;

	    public string TabHeaderTextBindPath
	    {
	        get { return tabHeaderTextBindPath; }
	        set { tabHeaderTextBindPath = value; }
	    }

	    public string TabHeaderTextKey
	    {
	        get { return tabHeaderTextKey; }
            set { tabHeaderTextKey = value;  }
	    }

	    public string SessionKey
		{
			get { return sessionKey; }
			set { sessionKey=value; }
		}

		public string HelpPage
		{
			get { return helpPage; }
			set { helpPage = value; }
		}

		public ISessionWrapper SessionWrapper
		{
			get { return sessionWrapper; }
			set { sessionWrapper = value; }
		}

		public IHelpManager HelpManager
		{
			set { helpManager = value; }
		}

		public string GetLocalizedContextHelpPath()
		{
			return helpManager.RelateHelpUrl(helpPage);
		}
        public string GetLocalizedContextHelpPath(string myHelpPage)
        {
            return helpManager.RelateHelpUrl(myHelpPage);
        }

	    
	    //----------------

	    public string PrintPageUrl
	    {
	        get { return printPageUrl; }
	        set { printPageUrl = value; }
	    }

	    public string EditPageUrl
        {
            get { return editPageUrl; }
            set { editPageUrl = value; }
        }

        public string AddPageUrl
        {
            get { return addPageUrl; }
            set { addPageUrl = value; }
        }

        public string GridClientVariable
        {
            get { return gridClientVariable; }
            set { gridClientVariable = value; }
        }

        public string FrameClientVariable
        {
            get { return frameClientVariable; }
            set { frameClientVariable = value; }
        }

        public string DelMessageKey
        {
            get { return delMessageKey; }
            set { delMessageKey = value; }
        }

        public string TabHeaderTextKeyBindPath
	    {
	        get { return tabHeaderTextKeyBindPath; }
            set { tabHeaderTextKeyBindPath = value; }
	    }

	    public string HelpPageBindPath
	    {
	        get { return helpPageBindPath; }
	        set { helpPageBindPath = value; }
	    }

	    public string HelpPageUnbindPath
	    {
	        get { return helpPageUnbindPath; }
	        set { helpPageUnbindPath = value; }
	    }
        public string HelpPagePath
        {
            set
            {
                helpPageBindPath = value;
                helpPageUnbindPath = value;
            }
        }

    }
}
